package com.softtown.modules.sys.dto;

import com.softtown.common.validator.group.UpdateGroup;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * @version v1.0
 * @ProjectName: softtown-aioffice
 * @ClassName: SysUserEmailDTO
 * @Description: 用户邮箱DTO
 * @Author: fuming
 * @Date: 2019/7/11 12:17
 */
@Data
@ApiModel(value = "用户邮箱")
public class SysUserEmailDTO implements Serializable {
    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "id")
    @NotNull(message="{id.require}", groups = UpdateGroup.class)
    private Long id;


    @ApiModelProperty(value = "新邮箱")
    @NotBlank(message="{sysuser.newemail.require}", groups = UpdateGroup.class)
    private String newEmail;

    @ApiModelProperty(value = "新验证码")
    @NotBlank(message="{sysuser.newemailcode.require}", groups = UpdateGroup.class)
    private String newEmailCode;

    @ApiModelProperty(value = "更新者ID")
    private Long updater;
}
